﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="ConsultarProjetos.aspx.cs" Inherits="CursoUNICEUB.ConsultarProjetos" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <h1>
        Lista de Projetos - SEP</h1>
        <asp:GridView ID="GridView1" runat="server" AllowSorting="True" AutoGenerateColumns="False"
            CellPadding="4" DataSourceID="ProjetosDataSource" ForeColor="#333333" 
        GridLines="None" AllowPaging="True">
            <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
            <Columns>
                <asp:TemplateField HeaderText="Nome">
                    <ItemTemplate>
                        <asp:LinkButton ID="lnbNome" Text='<%# Eval("Nome") %>' OnClick="lnbNome_Click" CommandArgument='<%# Eval("Codigo") %>'
                            runat="server"></asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="Descricao" HeaderText="Descricao" ReadOnly="True" 
                    SortExpression="Descricao" />
                <asp:BoundField DataField="Inicio" HeaderText="Inicio" ReadOnly="True"
                    SortExpression="Inicio" />
                <asp:BoundField DataField="FimPrevisto" HeaderText="FimPrevisto" ReadOnly="True"
                    SortExpression="FimPrevisto" />
                <asp:BoundField DataField="TamanhoSprint" HeaderText="TamanhoSprint" 
                    ReadOnly="True" SortExpression="TamanhoSprint" />
                <asp:BoundField DataField="Valor" HeaderText="Valor" ReadOnly="True" 
                    SortExpression="Valor" />
            </Columns>
            <EditRowStyle BackColor="#999999" />
            <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
            <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
            <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
            <SortedAscendingCellStyle BackColor="#E9E7E2" />
            <SortedAscendingHeaderStyle BackColor="#506C8C" />
            <SortedDescendingCellStyle BackColor="#FFFDF8" />
            <SortedDescendingHeaderStyle BackColor="#6F8DAE" />
        </asp:GridView>

    <asp:LinqDataSource ID="ProjetosDataSource" runat="server" 
        ContextTypeName="FastDATA.DCCursoDataContext" EntityTypeName="" 
        Select="new (Nome, Descricao, Inicio, FimPrevisto, TamanhoSprint, Valor)" 
        TableName="DEProjetos">
    </asp:LinqDataSource>

</asp:Content>
